﻿namespace BM.Tools.WebControls.MForm.Example
{
    using Controls;

    using Toolbox;

    public static class MFormToolboxNotifier
    {
        public static MFormToolbox NotifyToolbox(this Root root)
        {
            var site = root.Page.Master as Site;
            if (site == null)
            {
                return null;
            }

            site.ToolboxControl.MFormRoot = root;
            return site.ToolboxControl;
        }
    }
}
